!!! 5
html(lang="en")
	head
		meta(charset='UTF-8')
		title= 'ControlServer: ' + pageTitle
		link(rel='stylesheet',type='text/css',href='/static/style/main.css');
		script(type='text/javascript',src='/static/script/jquery-1.6.2.min.js')
	body
		user
			-if(typeof(user) == 'undefined')
				a#userClick.link(href='javascript:void()') Sign In
			-else
				a#userClick.link(href='javascript:void()')
					span(style='padding: 8px;')= user.firstName + ' ' + user.lastName
			#userInfo
				-if(typeof(user) != 'undefined')
					ul(style='display: inline-block; width: 224px;')
						li.neutral
							h4= user.firstName + ' ' + user.lastName
							div= user.email
						li.neutral.link(onclick='window.location=\'/users/' + user._id + '\'') Edit Profile
						li.neutral.link(onclick="logout();") Sign Out
				-else
					form#mainSingIn(
						method='post',
						action='/auth',
						enctype='application/x-www-form-urlencoded')
						ul
							li.neutral
								h3 Sign In
							li.neutral
								input(type='hidden',name='action',value='login')
								input(type='text',name='uname',value='User Name')
								input(type='text',name='passwd',value='Password')
							li.neutral.link(onclick='document.getElementById(\'mainSignIn\').submit()') Sign In
							li.neutral.link(onclick='window.location.href=\'/auth/create\'') Create Account
		#head
			h1 Control Server&nbsp;
			h2 An MQP @ WPI
		#navigation
			ul
				li.neutral
					h3 Navigation
				li.neutral(onclick='window.location=\'/\'') Dashboard
				li.neutral(onclick='window.location=\'/jsdoc/\'') API Documentation
				li.neutral Application Pages Here
				li.neutral(onclick='window.location=\'/log\'') Logging
				li.neutral
					h4 Settings
				li.neutral(onclick='window.location=\'/devices\'') Devices
				li.neutral(onclick='window.location=\'/ports\'') Ports
				li.neutral Access Control
		#page!= body
